//
//  CZSerchBar.m
//  CZOC微博01
//
//  Created by 1 on 15/11/28.
//  Copyright © 2015年 itcast. All rights reserved.
//

#import "CZSerchBar.h"

@implementation CZSerchBar


- (id)initWithFrame:(CGRect)frame
{
    if(self=[super initWithFrame:frame])
    {
        
        self.placeholder=@"请输入搜索内容";
        self.font=[UIFont systemFontOfSize:13];
        //    field.background=[UIImage imageNamed:@"tabbar_background"];
        self.backgroundColor=[UIColor lightGrayColor];
//        self.navigationItem.titleView=field;
        UIImageView *imageView=[[UIImageView alloc]init];
        imageView.image=[UIImage imageNamed:@"tabbar_discover"];
        imageView.width=20;
        imageView.height=20;
        imageView.frame=CGRectMake(10, 5, 30, 30);
        imageView.contentMode=UIViewContentModeCenter;
        
        self.leftView=imageView;
        
        self.leftViewMode=UITextFieldViewModeUnlessEditing;
        

    }
    return self;
}
+ (instancetype)serchBar
{
    return  [[self alloc] init];
}
@end

